home *** CD-ROM | disk | FTP | other *** search
- Path: damon.irf.uni.dortmund.de!broth
- From: rothert@damon.irf.uni-dortmund.de (Bernd Rothert)
- Newsgroups: comp.lang.c++
- Subject: Re: Incompatibility between BC4.5 32 bit DLL and MSVC 2.0 exe
- Date: Thu, 01 Feb 96 13:37:25 GMT
- Organization: Institute of Robotics Research
- Message-ID: <4eqfte$k3f@damon.irf.uni-dortmund.de>
- References: <4epure$k3p@idefix.eunet.fi>
- NNTP-Posting-Host: broth.irf
- X-Newsreader: News Xpress Version 1.0 Beta #4
-
- In article <4epure$k3p@idefix.eunet.fi>,
- Planmeca Oy <fipdt4d9@ibmmail.com> wrote:
- >We have a "minor" problem. Part of our development team is developing
- >(32 bit) DLL:s with BC4.5 c++. Another part is developing the application
- >which needs to use that DLL. While trying to build the executable with
- >the LIB generated by BC for that DLL, MSVC complains: invalid or
- >corrupted library file.
-
- There may be another problem besides the compatibility of the import library
- formats: I tried the same mix with 16-bit code (GUI with MSVC 1.51, kernel
- with BC++ 4.5) - it didn't work. After "some" debugging I discovered that some
- of the the BC++ 4.5 compiled DLL functions modified the callers data segment
- contents when exception handling has been enabled(the default). The BC++ 4.5
- code uses some absolute addresses inside the stack segment (= caller's DS) for
- exception handling.
-
- The modification of the caller's data segment is not a problem if the .EXE has
- been compiled with BC++ 4.5. The critical area is DS:0014H - DS:0037H where
- the compiler stores its exception list etc. - see \BC45\lib\startup\c0w.asm
- and c0d.asm
-
- I also doubt if you can import objects in a MSVC-EXE exported by a BC45-DLL
- (different internal representations!?).
-
- Bernd
-